1. Field of the Invention
The present invention generally relates to image processing technology for controlling the position of polygons, and particularly to a game device for displaying game screens thereby.
2. Description of the Related Art
Regarding a usual game device, a game is developed by operating an input device and controlling movements of objects while watching a screen. Regarding a game device of a 3D (3 dimensional) display, a virtual space is formed in a computer system, wherein objects of the game are arranged. The computer controls the movements of the objects in accordance with the game rules. The computer also develops the game by controlling the object of a main character in accordance with operation by a player. Development of the game is displayed on a monitor screen through a virtual camera arranged in the virtual space.
Each object is usually constituted of a plurality of polygons, and each polygon is constituted of more than 3 vertexes. Each vertex constituting a polygon is normally specified by the coordinates in the virtual space where the polygon is arranged in. Consequently, the motions of the object in a virtual space are finally considered as conversions of the vertex coordinates of the polygon constituting the object.
As objects, a main character, and other characters can be considered as well as shapes of nature, such as geographical features, plants, animals, buildings. Modeling a character can be achieved more realistically by representing a character by a plurality of objects (for example, an object representing a body and an object representing clothes, accessories, or shoes, etc.) rather than by a single object.
At this point, physical mixture of a body, clothes, accessories, and shoes etc. can not principally occur in the real world. Therefore, regarding the objects in the virtual space such as a body and clothes, they need to be arranged physically compatible with each other. FIG. 13 shows an example that object 400 representing a body and object 401 representing a cloth are arranged physically incompatible with each other. In this example, Part 402 of the object representing a body penetrates object 401 representing a cloth.
To prevent such arrangement, it is necessary, on moving an object, to fix coordinates of the next position of the polygons constituting such object, so that there is no intersection with other polygons constituting other polygons.
The following example is a method for fixing coordinates of such next position in order not to cause intersection. In the following description, a body polygon refers to a polygon constituting an object representing a body, and a cloth polygon refers to a polygon constituting an object representing clothes.
The first method is to fix the relation between the positions of 2 kinds of polygons (a body polygon and a cloth polygon). In this method, once a position of one polygon is decided, the position of the other polygon is also decided, therefore, there is no intersection of the 2 polygons no matter where the objects move to.
The second method is, in the event that such motion of objects cause intersections, to amend the vertex coordinates of one polygon so that there will be no intersection. FIG. 14 shows a concept representation to describe the second method. FIG. 14(a) shows the vertex coordinates before and (b) shows the vertex coordinates after amendment. 400 is an object representing a body and 401 is an object representing clothes.
This method is premised on calculating the vertex coordinates after the independent motions of each of the 2 kinds of polygons, without fixing the relation between. Therefore, as a result of independent calculation of each polygon, and as shown in FIG. 14, if the vertex 403 after movement of the cloth polygon is placed inside object 400 representing a body, there is a possibility of intersection 404 of the 2 kinds of polygons. In such case, if the second method is applied, the coordinates of vertex 403 are amended to be outside of object 400 representing a body. Thereby, the 2 kinds of polygons can be amended not to intersect as shown in FIG. 14(b).
However, the above usual methods generate the following problems.
Firstly, the first method has a problem that dynamic and realistic movements cannot be achieved for the relation of the 2 kinds of polygons is always fixed.
For a game of 3D display, the main factor of its attraction depends on how real the real world can be simulated. For a real simulation, for example, it is necessary to dynamically show in the virtual space the phenomenon in the real world such as xe2x80x9cwhen a character runs, its clothes flutter backward because of the wind.xe2x80x9d
In the first method, however, the 2 kinds of polygons are permitted the same movement for a cloth polygon is fixedly arranged against a body polygon. This only gives an impression that the clothes are as hard as an armor, and so it is impossible to implement dynamic and realistic movements regarding the clothes. Therefore, the content of the display of the game is very unattractive.
The second method has a problem that it cannot perfectly prevent the intersection of the 2 kinds of polygons.
Compared to the first method, the second method surely implements the dynamic and real movements as it permits independent movements respectively to a cloth polygon and a body polygon.
However, although the vertexes of a cloth polygon are amended and placed outside an object representing a body, there is still a possibility of intersection. For example, as shown in FIG. 15, all the vertexes of the cloth polygon are placed outside the object representing a body, but there is intersection 404 of the 2 kinds of polygon. In this situation, a part of the body penetrates the clothes. This is a physically incompatible and unnatural situation. Therefore, it gives incompatibility to the content of the display of the game.
At this point, it is possible to lessen the possibility of intersections by increasing the number of cloth polygon (i.e. the number of vertexes). However, increasing the number of polygon is not desirable because it results in an increase of the processing amount of the coordinate calculation. Furthermore, even if the number of polygon is increased, it is still difficult to completely prevent the occurrence of intersections.
The object of the present invention, with regard to polygons constituting an object, is not to increase its number but provide image processing technology which permits the prevention of intersections of such polygons with other polygons of other objects.
Another purpose of the present invention is to represent dynamic and realistic movements with no incompatibility.
The image processing method of the present invention is characterized in that it is an image processing method for, corresponding the vertexes of the polygons constituting a first object, recording a positioning condition regarding a position corresponding a second object on a recording means, judging whether the vertexes constituting such first object satisfy the previous condition, and, if judged not, amending the positions of such vertexes to satisfy the condition; that the polygons constituting such first object and the polygons constituting such second object do not intersect.
The game method of the present invention is a game method for arranging objects in a virtual space formed in a computer system, developing a game while controlling the movements of such objects in accordance with the input manipulation and regulated rules, and displaying the situation inside such virtual space as an image through a virtual camera, and is characterized in that the coordinates of the polygon constituting such object are amended by the image processing method of the present invention.
The image compressing method and the game method according to the present invention can be implemented by a computer. The computer program for such purpose can be or loaded to the computer through various media such as CD-ROM, magnetic discs, semiconductor memory and communication network.
The image processing device is comprising a positioning condition memorizing means for, corresponding the vertexes of the polygon constituting the first object, memorizing a condition regarding the position corresponding the second object, and a polygon position amending means for, referring to such positioning condition memorizing means, judging whether the vertexes of the polygon constituting such first object satisfy such condition, and, if it judges that the condition is not satisfied, for amending the positions of such vertexes, and is characterized in that such condition is that the polygons constituting such first object and the polygons constituting such second object do not intersect.
The game device according to the present invention is a game device for arranging objects in a virtual space formed in a computer system, developing a game while controlling the movements of such objects in accordance with input operation and regulated rules, and displaying the situation inside such virtual space as an image through a virtual camera, and is characterized in that it is comprising a image processing device according to the present invention.
Regarding such positioning condition memorizing means, it is desired to memorize, as such condition, the area established relative to such second object, particularly a plane area.
Among 4 plane areas divided by 2 straight lines which are extensions of 2 arbitrary adjacent sides of a polygon circumscribing the circumcircle which is circumscribing the second object on the plane, it is desired that such area is contained in a plane area facing another plane area containing such circumcircle, and it is also desired that such area is a circular area contacting such 2 straight lines.
It is desired that such positioning condition memorizing device records, as such area, at least a circular area, contacting from the opposite side of such circumcircle of 2 straight lines which are extensions of 2 arbitrary adjacent sides of a plane polygon circumscribing the circumcircle which is circumscribing the second object on the plane. It is also desired to record a circular area contacting, from the opposite side of such circumcircle, the extended straight line of one optional side of such polygon.
It is desired that such polygon position amending means judges whether the vertexes of the polygon constituting such first object are included in such area, and, if judges not, amends the positions of the vertexes to be included in such area.
It is desired that such first object is arranged to cover at least a part of such second object, and particularly that such first object is an object representing a material a person is wearing and such second object is an object representing a human body of a material the person is wearing.